-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[typescript-operations/client-preset] Next major version #10496
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: b55828d The changes in this PR will be included in the next version bump. This PR includes changesets to release 11 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
🚀 Snapshot Release (
|
| Package | Version | Info |
|---|---|---|
@graphql-codegen/cli |
6.1.1-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/introspection |
5.0.1-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/visitor-plugin-common |
7.0.0-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/typescript-document-nodes |
5.0.8-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/gql-tag-operations |
5.1.3-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/typescript-operations |
6.0.0-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/typescript-resolvers |
6.0.0-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/typed-document-node |
6.1.6-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/typescript |
6.0.0-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/client-preset |
6.0.0-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
@graphql-codegen/graphql-modules-preset |
5.1.3-alpha-20260115135723-b55828d4ea802db1476fb7eaada41592b9c80985 |
npm ↗︎ unpkg ↗︎ |
ecee891 to
f999b72
Compare
* Create standalone test * Add Exact and set up test * Remove Exact from typescript plugin * Update tests that switch out Exact * Update dev tests * Add changeset * Update test * Add InputMaybe Scalars tests * Fix schema in test * Fix up examples tests * Add result enum example
* [typescript-operations] Remove generation of InputMaybe and Scalars for variables * Adding support for `config.scalars`, fixing intergation tests --------- Co-authored-by: Igor Kusakov <[email protected]>
…ring and getNodeComment to `visitor-plugin-common` (#10520) * Extract convertSchemaEnumToDeclarationBlockString and getNodeComment to visitor-plugin-common to re-use in next major version * Create major breaking changeset for @graphql-codegen/visitor-plugin-common * Fix naming * Replace buildEnumValuesBlock method in base-types-visitor with a utility version * Fix changeset * Fix import path * Fix getNodeComment import issue by moving to utils.ts
…les (#10508) * Collect used enums * Use enum converter for Enum * Add changeset * Add doc * Update dev tests * Fix return type issue
…logic for standalone approach (#10525) * Add tests for enum * Baselin tests * Ensure correctness of enumValues import * Split enum tests * Abstract import printing functions * Add missing enum tests * Format to minimise conflict * Add changeset
…ned+used input/enum types externally (#10534) * Draft importSchemaTypesFrom * Minor test fixes * Fix test name * Update dev-tests * Baseline dev-test for importSchemaTypesFrom * Implement relative import paths correctly * Update tests to handle outputDir correctly * Add test for absolute importSchemaTypesFrom * Remove unncessary files * Add test about unused things * Remove comment * Add comments * Add changeset
…tions with client preset (#10540) * Do not use typescript and its config in Client Preset * Fix issue where enumValues are imported even if not used * Split enum tests for client preset * Update unit tests * Update examples * Generate Incremental utilty type * Add changeset * Rebase tests (with errors)
… conditional (#10548) * Fix types issues and put comments * Handle avoidOptionals * Update integration tests * Add FIXME to pass test for now * Add changeset
… on `typescript` plugin (`preResolveTypes: false`) (#10556) * Remove legacy selection set proccessor that depends on typescript plugin * Remove obsolete tests * Improve tests to be explicit
* Refactor utility function to match practice * Fix config option inheritance - addTypename/skipTypename: is only a types-visitor concern. This is moved to types-visitor from base-visitor - nonOptionalTypename: is a documents-visitor and types-visitor concern. Moved from base-visitor there - extractAllFieldsToTypes: is a documents-visitor concern. Moved from base-visitor there - enumPrefix and enumSuffix: need to be in base-visitor as all 3 types of visitors need this to correctly sync the enum type names. This is moved to base visitor - ignoreEnumValuesFromSchema: is a documents-visitor and types-visitor concern. Moved from base-visitor there. - globalNamespace: is a documents-visitor concern. Moved from base-visitor there Other changes: - documents-visitor no longer extends types-visitor _option types_ as they have two distinct usages now. The types now extend base-visitor types. This is now consistent with documents-visitor extending base-visitor - Classes now handle config parsing and types at the same level e.g. if typescript-operations plugin parses configOne, then the types for configOne must be in that class, rather than in base-documents-visitor * Remove references and tests related to skipTypename in operations plugin * Add changeset
* Fix missing dep * chore(dependencies): updated changesets for modified dependencies * Fix dev-tests --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
💻 Website PreviewThe latest changes are available as preview in: https://pr-10496.graphql-code-generator.pages.dev |
* Remove MakeOptional MakeMaybe MakeEmpty and Incremental utitlity types from typescript plugin because they were used for typescript-operations * Fix unit tests * Remove deprecated functions * Add changeset
…lo-tooling), v2 (#10568) * add extractAllFieldsToTypesCompact config option * adding changeset * fixing duplication bug * duplication bug fix --------- Co-authored-by: Igor Kusakov <[email protected]>
* Remove extraneous test setup * Do not generate Exact utility type of not used * Add default test case to check that Exact is used for Mutation and Subscription variables * Update dev-tests * Add changeset * Remove extraneous config for Exact test
* Make default scalar unknown, instead of any * Set up defaultScalarType tests * Add changeset * Revert unrelated null | undefined changes * Fix test description * Add a test case for custom scalar in dev-test
…types (#10573) * Shuffle methods to group things together, cleanup * Wire up _inputMaybeValue and organise config * Wire up inputMaybeValue * Add inputMaybeValue test * Update tests * Add changeset
This is the feature branch for #10479
Checklist
typescript-operations
@eddeee888 [typescript-operations] Generate
Exactinto target file #10504@ikusakov2 [typescript-operations] Remove inputmaybe and scalars #10509
@eddeee888 Generate Enum used in Variables into target file
visitor-plugin-common#10520@ikusakov2 Generate input types and output enums into target file #10527
@ikusakov2 Add config extract all fields to types field names only (same as apollo-tooling), v2 #10568
@ikusakov2 Bugfix: enums from external fragments were not generated along with operations #10565
@eddeee888 [typescript-operations] Add generatesOperationTypes config option #10529
@eddeee888 [typescript-operations] Add importSchemaTypesFrom to import user-defined+used input/enum types externally #10534
@eddeee888 [typescript-operations] No optional Result fields, unless deferred or conditional #10548
@eddeee888 [typescript-operations] Fix __typename optionality and nullability #10552
@eddeee888 [typescript-operations] Clean up selection set processor that depends on
typescriptplugin (preResolveTypes: false) #10556@eddeee888 Adjust config inheritance to reflect usage and type-hint better #10560
@eddeee888 Fix issues after rebasing #10563
@eddeee888 Remove unused utility types and functions #10564
@eddeee888 Make
unknowninstead ofanythe default scalar type #10566@eddeee888 Only generate
Exactutility type if documents have operations #10571@eddeee888 Decouple
typescript-operationsplugin fromtypescriptplugin #10572@eddeee888 Re-implement
inputMaybeValueto allow changing Variables and Input nullable types #10573Handle nullable
anyandunknownAdd
generatesSharedTypesto generate enum and input typesTODO:
config.addOperationExportconfig.globalNamespaceconfig.avoidOptionalsto see which key/value are used inoperationsplugindirectiveArgumentAndInputFieldMappingsis neededtypescriptandtypescript-operations'sInputValueDefinition@skip/@includedirectives on fragments. Must work with FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENTclient-preset
Verify fixes
extractAllFieldsToTypeshandling of nested interfaces in type names #10502